home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Tech Arsenal 1
/
Tech Arsenal (Arsenal Computer).ISO
/
tek-01
/
lcppb.zip
/
LCPPANS.ZIP
/
CIRCUM.CPP
< prev
next >
Wrap
C/C++ Source or Header
|
1991-07-08
|
557b
|
25 lines
// circum.cpp -- Calculate circumference of a circle
#include <iostream.h>
#include <stdlib.h>
#define PI 3.14159
main()
{
char response[129]; // Holds response to prompt
cout << "Calculate circumference of a circle.";
cout << "\nDiameter? ";
cin >> response;
cout << "Circumference = " << (PI * atof(response));
}
// Copyright (c) 1990 by Tom Swan. All rights reserved
// Revision 1.00 Date: 10/23/1990 Time: 04:38 pm
// Revision 1.01 Date: 07/08/1991 Time: 05:41 pm
// Converted for Borland C++ 2.0